Recognizing Algorithms Using Roles of Variables, Language Constructs and Software Metrics: A Machine Learning Approach

نویسنده

  • Ahmad Taherkhani
چکیده

Roles of Variables (RoV) are concepts that describe the behavior and usage of variables in computer programs. RoV have originally been introduced to help novices learn programming. Algorithm Recognition (AR) is a subfield of program comprehension, where the problem is to identify algorithms from the source code. AR covers recognizing different algorithms that carry out different computational task, as well as different types of algorithms that perform the same task. The main application of AR is in automatic assessment of students' programs to verify that the program implements the required algorithm. This thesis investigates the applicability and usefulness of RoV in AR. The idea is to analyze different implementations of basic algorithms to see whether RoV appear in those algorithms is such a way that they can be distinguished on this basis. In addition to RoV, other distinctive characteristics that can be used in the recognition process are also identified from the algorithms. These characteristics are related to language constructs and various software metrics. Based on the results of these analyses, a method for AR is introduced and a tool for automatic algorithm recognition is developed. Two experiments on sorting algorithms are carried out to illustrate the feasibility of the AR method. In the first experiment, sorting algorithms are recognized using a manually constructed decision tree. The second experiment uses the C4.5 algorithm to construct the decision tree. The results of the experiments (86% and 97.1% correctly recognized algorithms respectively) show the applicability of RoV and the other characteristics in AR problem. Moreover, the performance of the automatically constructed decision tree demonstrates that machine learning techniques are also suitable for AR task. and was partially funded by the Academy of Finland. I would like to thank my supervisor, Professor Lauri Malmi, for providing me the opportunity to do this work. I highly appreciate his valuable input, feedback and suggestions during the project. I am sincerely thankful to him. I am also grateful to my instructor, Docent Ari Korhonen, for his insightful comments, helpful ideas and great discussions. Finally, I would like to express my greatest gratitude to my family; my wife, Elmira, my daughter Ava and my son Arad, for their love, understanding and encouragement, as well as my parents for their support over the years. This paper discusses roles of variables, their application to algorithm recognition and introduces a method for algorithm recognition. It also presents an extensive literature …

برای دانلود رایگان متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

Recognizing Algorithms Using Language Constructs, Software Metrics and Roles of Variables: An Experiment with Sorting Algorithms

Program comprehension (PC) is a research field that has been extensively studied from different points of view, including human program understanding and mental models, automated program understanding, etc. In this paper, we discuss algorithm recognition (AR) as a subfield of PC and explain their relationship. We present a method for automatic AR from Java source code. The method is based on st...

متن کامل

Machine learning algorithms for time series in financial markets

This research is related to the usefulness of different machine learning methods in forecasting time series on financial markets. The main issue in this field is that economic managers and scientific society are still longing for more accurate forecasting algorithms. Fulfilling this request leads to an increase in forecasting quality and, therefore, more profitability and efficiency. In this pa...

متن کامل

ارائه الگوریتمی مبتنی بر یادگیری جمعی به منظور یادگیری رتبه‌بندی در بازیابی اطلاعات

Learning to rank refers to machine learning techniques for training a model in a ranking task. Learning to rank has been shown to be useful in many applications of information retrieval, natural language processing, and data mining. Learning to rank can be described by two systems: a learning system and a ranking system. The learning system takes training data as input and constructs a ranking ...

متن کامل

The Correlation of Machine Translation Evaluation Metrics with Human Judgement on Persian Language

Machine Translation Evaluation Metrics (MTEMs) are the central core of Machine Translation (MT) engines as they are developed based on frequent evaluation. Although MTEMs are widespread today, their validity and quality for many languages is still under question. The aim of this research study was to examine the validity and assess the quality of MTEMs from Lexical Similarity set on machine tra...

متن کامل

Automatic Algorithm Recognition Based on Programming Schemas and Beacons - A Supervised Machine Learning Classification Approach

Aalto University, P.O. Box 11000, FI-00076 Aalto www.aalto.fi Author Ahmad Taherkhani Name of the doctoral dissertation Automatic Algorithm Recognition Based on Programming Schemas and Beacons: A Supervised Machine Learning Classification Approach Publisher Aalto University School of Science Unit Department of Computer Science and Engineering Series Aalto University publication series DOCTORAL ...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

عنوان ژورنال:

دوره   شماره 

صفحات  -

تاریخ انتشار 2013